package day240918.lambda.demo05;

public class Test {
    public static void main(String[] args) {
        MyInterface my=new MyInterface() {
            @Override
            public Integer str2Int(String str) {
                return Integer.parseInt(str);
            }
        };

        MyInterface my1=(p)->{
            return Integer.parseInt(p);
        };


        MyInterface my2=Integer::parseInt;

        System.out.println(my.str2Int("123"));
        System.out.println(my1.str2Int("123"));
        System.out.println(my2.str2Int("123"));
    }
}
